﻿using BCCommon.Enums;
using BCDto.IM.CustomerService;
using System;
using System.Collections.Generic;
using System.Text;

namespace BCService.IM.CustomerService
{
    /// <summary>
    /// 在线客服服务接口
    /// </summary>
    public interface ICustomerService
    {
        /// <summary>
        /// 客服上线。
        /// </summary>
        void Connect();

        /// <summary>
        /// 客服下线。
        /// </summary>
        void Disconnect();

        /// <summary>
        /// 获取通用的可用客服。
        /// </summary>
        /// <param name="businessType">业务类型。</param>
        /// <param name="countyCode">县/区代码。</param>
        /// <returns></returns>
        CustomerServiceDto GetRepresentative(string businessType, string countyCode);
        
        /// <summary>
        /// 建立客服与客户的连接。
        /// </summary>
        /// <param name="businessType">业务类型。</param>
        /// <param name="referenceNumber">原业务编号。</param>
        /// <param name="adminId">员工编号。</param>
        /// <param name="userType">用户类型。</param>
        /// <param name="userId">用户编号。</param>
        void Touch(string businessType, string referenceNumber, long adminId, RoleType userType, long userId);

        /// <summary>
        /// 断开客服与客户的连接。
        /// </summary>
        /// <param name="businessType">业务类型。</param>
        /// <param name="referenceNumber">原业务编号。</param>
        /// <param name="adminId">员工编号。</param>
        /// <param name="userType">用户类型。</param>
        /// <param name="userId">用户编号。</param>
        /// <param name="reason">原因。</param>
        void Drop(string businessType, string referenceNumber, long adminId, RoleType userType, long userId, string reason);
    }
}
